package com.labtalk.admin.controller;

import com.labtalk.admin.pojo.common.ResponseVo;
import com.labtalk.admin.service.InfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/api")
public class InfoController {

    @Autowired
    InfoService infoService;

    @GetMapping("/getPassword")
    public ResponseVo getPassword(@RequestParam("password") String password) {
        return infoService.getPassword(password);
    }

    @GetMapping("/getInfo")
    public ResponseVo getList() {
        return infoService.getInfo();
    }
}
